home *** CD-ROM | disk | FTP | other *** search
/ PC World 2007 December / PCWorld_2007-12_cd.bin / domacnost a kancelar / autoit / autoit-v3-setup.exe / Examples / Helpfile / GUICtrlCreateSlider.au3 < prev    next >
Text File  |  2007-09-08  |  529b  |  21 lines

  1. #include <GUIConstants.au3>
  2.  
  3. GUICreate("slider",220,100, 100,200)
  4. GUISetBkColor (0x00E0FFFF)  ; will change background color
  5.  
  6. $slider1 = GUICtrlCreateSlider (10,10,200,20)
  7. GUICtrlSetLimit(-1,200,0)    ; change min/max value
  8. $button = GUICtrlCreateButton ("Value?",75,70,70,20)
  9. GUISetState()
  10. GUICtrlSetData($slider1,45)    ; set cursor
  11.  
  12. $start=TimerInit()
  13. Do
  14.   $n = GUIGetMsg ()
  15.       
  16.    If $n = $button Then
  17.       MsgBox(0,"slider1",GUICtrlRead($slider1),2)
  18.    $start=TimerInit()
  19.    EndIf
  20. Until $n = $GUI_EVENT_CLOSE
  21.